<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>YaCy '#[clientname]#': Blog</title>
    #%env/templates/metas.template%#
    <link rel="alternate" type="application/rss+xml" title="RSS" href="Blog.rss" />
  </head>
  <body id="Blog">
    #(display)#
    #%env/templates/simpleheader.template%#
    #%env/templates/submenuPublication.template%#
    ::
    #%env/templates/header.template%#
    #%env/templates/submenuPublication.template%#
	::
	#%env/templates/embeddedheader.template%#
    #(/display)#
    #(mode)#
    <!-- 0: viewing -->
    #{entries}#
    <div class="Post">
      <h2 class="PostSubject"><a href="BlogComments.html?page=#[pageid]#">#[subject]#</a></h2>
      <div class="PostBody">#[page]#</div>
      <p class="PostInfo">
        #[date]# | by #[author]# #(commentsactive)#::| <a href="BlogComments.html?page=#[pageid]#">#[comments]# Comments</a>#(/commentsactive)#
        #(admin)#::| <a href="Blog.html?page=#[pageid]#&amp;edit=true">edit</a>
        - <a href="Blog.html?page=#[pageid]#&amp;delete=try">delete</a>#(/admin)#
      </p>
    </div>
    #{/entries}#
    <div class="BlogCommentPrevNext">
      <p>
      #(preventries)#
        &lt;&lt; previous entries
      ::
        <a href="Blog.html?start=#[start]#&amp;num=#[num]#">&lt;&lt; previous entries</a>
      #(/preventries)#
      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
      #(moreentries)#
        next entries &gt;&gt;
      ::
        <a href="Blog.html?start=#[start]#&amp;num=#[num]#">next entries &gt;&gt;</a>
      #(/moreentries)#
    </p>
    </div>
    <p class="Navigation">
      #(admin)#<a href="Blog.html?login=true">Login</a> - ::<a href="Blog.html?edit=true">new entry</a> - <a href="Blog.html?import=xml">import XML-File</a> - <a href="Blog.xml?xml=1">export as XML</a> - #(/admin)#<a href="Blog.html">Blog-Home</a>
    </p>
    ::
    <!-- 1: edit -->
    <h2>Edit</h2>
    <form action="Blog.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
      <fieldset>
        <dl>
          <dt><label for="author">Author:</label></dt>
          <dd>
            <input name="author" id="author" type="text" size="20" maxlength="80" value="#[author]#" />
          </dd>
          <dt><label for="subject">Subject:</label></dt>
          <dd>
            <input name="subject" id="subject" type="text" size="80" maxlength="80" value="#[subject]#" />
          </dd>
          <dt><label for="content">Text:</label></dt>
          <dd>
            <textarea name="content" id="content" cols="80" rows="24">#[page-code]#</textarea>
            <p class="help">
              You can use <a href="WikiHelp.html" onclick="window.open('WikiHelp.html','WikiHelp','toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=640,height=480');return false;">Yacy-Wiki Code</a> here.
            </p>
          </dd>
          <dt><label for="commentMode">Comments:</label></dt>
          <dd>
            <select name="commentMode" id="commentMode">
              <option value="0" #(commentMode)#selected="selected"::#(/commentMode)#>deactivated</option>
              <option value="1" #(commentMode)#::selected="selected"#(/commentMode)#>activated</option>
              <option value="2" #(commentMode)#::::selected="selected"#(/commentMode)#>moderated</option>
            </select>
          </dd>
        </dl>
        <input type="hidden" name="page" value="#[pageid]#" />
        <input type="submit" name="submit" class="btn btn-primary" value="Submit" />
        <input type="submit" name="preview" class="btn btn-default" value="Preview" />
        <input type="submit" name="discard" class="btn btn-danger" value="Discard" />
      </fieldset>
    </form>
    ::
    <!-- 2: preview -->
    <h2>Preview</h2>
    <p>No changes have been submitted so far!</p>
    <div class="Post">
      <h2 class="PostSubject">#[subject]#</h2>
      <div class="PostBody">#[page]#</div>
      <p class="PostInfo">#[date]# | by #[author]#</p>
    </div>
    <form action="Blog.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
      <fieldset>
        <dl>
          <dt><label for="author">Author:</label></dt>
          <dd>
            <input name="author" id="author" type="text" size="20" maxlength="80" value="#[author]#" />
          </dd>
          <dt><label for="subject">Subject:</label></dt>
          <dd>
            <input name="subject" id="subject" type="text" size="20" maxlength="80" value="#[subject]#" />
          </dd>
          <dt>
            <label for="content">Text:</label>
          </dt>
          <dd>
            <textarea name="content" id="content" cols="80" rows="24">#[page-code]#</textarea>
            <p class="help">
              You can use <a href="WikiHelp.html" onclick="window.open('WikiHelp.html','WikiHelp','toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=640,height=480');return false;">Yacy-Wiki Code</a> here.
            </p>
          </dd>
          <dt><label for="commentMode">Comments:</label></dt>
          <dd>
            <select name="commentMode" id="commentMode">
              <option value="0" #(commentMode)#selected="selected"::#(/commentMode)#>deactivated</option>
              <option value="1" #(commentMode)#::selected="selected"#(/commentMode)#>activated</option>
              <option value="2" #(commentMode)#::::selected="selected"#(/commentMode)#>moderated</option>
            </select>
          </dd>
        </dl>
        <input type="hidden" name="page" value="#[pageid]#" />
        <input type="submit" name="submit" class="btn btn-primary" value="Submit" />
        <input type="submit" name="preview" class="btn btn-default" value="Preview" />
        <input type="submit" name="discard" class="btn btn-danger" value="Discard" />
      </fieldset>
    </form>
    ::
    <!-- 3: Access Denied (no rights) -->
    <h3>Access denied</h3>
    <p>To edit or create blog-entries you need to be logged in as Admin or User who has Blog rights.</p>
    ::
    <!-- 4: Delete Confirmation -->
    <h3>Are you sure...</h3>
    <p>... that you want to delete <strong>#[subject]#</strong> by <span class="tt">#[author]#</span>?</p>
    <fieldset><legend>Confirm deletion</legend>
      <form action="Blog.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
        <input type="hidden" name="delete" value="sure" />
        <input type="hidden" name="page" value="#[pageid]#" />
        <input type="submit" class="btn btn-danger" value="Yes, delete it." />
      </form>
      <form action="Blog.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
        <input type="submit" class="btn btn-primary" value="No, leave it." />
      </form>
    </fieldset>
    ::
    <!-- 5: XML-Import -->
    <h3>XML-Import</h3>
    #(state)#
    ::
    <p>Import was successful!</p>
    ::
    <p>Import failed, maybe the supplied file was no valid blog-backup?</p>
    #(/state)#
    <p>Please select the XML-file you want to import:</p>
    <form action="Blog.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
      <fieldset>
        <input type="file" size="50" name="xmlfile" />
        <input type="submit" name="importxml" class="btn btn-primary" value="Import" />
      </fieldset>
    </form>
    #(/mode)#
  #%env/templates/footer.template%#
  </body>
</html>
